﻿using Tb.App.Domain.Rabbit.Basic;

namespace Tb.App.API.Applications.DTOs
{
    /// <summary>
    /// 溯源信息DTO
    /// </summary>
    public class TraceabilityDTO
    {
        public BasicModelDTO Basic { get; set; }
        public CultivationModelDTO Cultivation { get; set; }
        public DeepProcessingModelDTO DeepProcessing {  get; set; }
        public SlaughterModelDTO Slaughter { get; set; }
    }
    /// <summary>
    /// 基本信息DTO
    /// </summary>
    public record BasicModelDTO 
    {
        public int Id { get; set; }
        /// <summary>
        /// 商品名称Id
        /// </summary>
        public int Sid { get; set; }
        /// <summary>
        /// 生产批次
        /// </summary>
        public string? Batch { get; set; }
        /// <summary>
        /// 保质期
        /// </summary>
        public int Expiration { get; set; }
        /// <summary>
        /// 生产许可证号
        /// </summary>
        public string? License { get; set; }
        /// <summary>
        /// 生产企业
        /// </summary>
        public string? Company { get; set; }
    }
    public record CultivationModelDTO
    {
        /// <summary>
        /// 品种
        /// </summary>
        public string? Variety { get; set; }
        /// <summary>
        /// 来源
        /// </summary>
        public string? Source { get; set; }
        /// <summary>
        /// 饲养天数
        /// </summary>
        public int RearingDays { get; set; }
        /// <summary>
        /// 品牌
        /// </summary>
        public string? Brand { get; set; }
        /// <summary>
        /// 饲养负责人
        /// </summary>
        public string? RearingLeader { get; set; }
        /// <summary>
        /// 出栏日期
        /// </summary>
        public DateTime? OutDate { get; set; }
        /// <summary>
        /// 生产批次
        /// </summary>
        public string? Batch { get; set; }
    }
    public record DeepProcessingModelDTO
    {
        /// <summary>
        /// 班组
        /// </summary>
        public string? Team { get; set; }
        /// <summary>
        /// 负责人
        /// </summary>
        public string? Leader { get; set; }
        /// <summary>
        /// 生产批次
        /// </summary>
        public string? Batch { get; set; }
    }

    public record SlaughterModelDTO
    {
        /// <summary>
        /// 生产批次
        /// </summary>
        public string? Batch { get; set; }
        /// <summary>
        /// 到场均重
        /// </summary>
        public int Weight { get; set; }
    }

}
